home *** CD-ROM | disk | FTP | other *** search
/ Scene Storm / Scene Storm - Volume 1.iso / coding / c / pdc / libsrc / stringlib / index.c < prev    next >
Encoding:
C/C++ Source or Header  |  1990-04-07  |  262 b   |  17 lines

  1. /*
  2.  * index - find first occurrence of a character in a string
  3.  */
  4.  
  5. #include "config.h"
  6. #define    NULL    0
  7.  
  8. char *                /* found char, or NULL if none */
  9. index(s, charwanted)
  10. CONST char *s;
  11. char charwanted;
  12. {
  13.     extern char *strchr();
  14.  
  15.     return(strchr(s, charwanted));
  16. }
  17.